/*
 * ModelItem.java
 *
 * Created on August 1, 2006, 9:55 AM
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package com.smallx.xproc;

import java.net.URI;
import org.infoset.xml.Location;
import org.infoset.xml.Name;

/**
 *
 * @author alex
 */
public class ModelItem implements Location {

   int line;
   int column;
   Name itemName;
   URI baseURI;
   
   protected ModelItem(Name name) {
      this.itemName = name;
      this.baseURI = null;
      this.column = 0;
      this.line = 0;
   }
   
   public URI getBaseURI() {
      return baseURI;
   }
   
   public Name getName() {
      return itemName;
   }
   
   public void setLocation(URI baseURI,int line, int column) {
      this.baseURI = baseURI;
      this.line = line;
      this.column = column;
   }
   
   public void setLocation(URI baseURI,Location location) {
      this.baseURI = baseURI;
      this.line = location.getLine();
      this.column = location.getColumn();;
   }
   
   public int getColumn() {
      return column;
   }
   
   public int getLine() {
      return line;
   }
   
   public void setLine(int line) {
      this.line = line;
   }
   
   public void setColumn(int column) {
      this.column = column;
   }

}
